﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel.DataAnnotations;

namespace ABCTile.Models
{
	public class Company
	{
		[Key]
		public Int32 ID { get; set; }

		[Display(Name = "Branch Sequence")]
		[Required(ErrorMessage = "Branch is required")]
		public string Branch_Seq { get; set; }

		[Display(Name = "Contact Role")]
		[Required(ErrorMessage = "Contact Role is required")]
		public string Contact_Role { get; set; }

		[Display(Name = "Contact Person ID")]
		[Required(ErrorMessage = "Contact Person_ID is required")]
		public string Contact_Person_ID { get; set; }

		[Display(Name = "Company Name")]
		[Required(ErrorMessage = "Company Name is required")]
		public string Company_Name { get; set; }

		[Display(Name = "Office Phone")]
		[DataType(DataType.PhoneNumber)]
		[Required(ErrorMessage = "Office Phone is required")]
		public string Office_Phone { get; set; }

		[Display(Name = "Office Fax")]
		[Required(ErrorMessage = "Office Fax is required")]
		[DataType(DataType.PhoneNumber)]
		public string Office_Fax { get; set; }

		[Display(Name = "Cell Phone")]
		[Required(ErrorMessage = "Cell Phone is required")]
		[DataType(DataType.PhoneNumber)]
		public string Cell_Phone { get; set; }

		[Display(Name = "Company Website")]
		[Required(ErrorMessage = "Company URL is required")]
		[DataType(DataType.Url)]
		public string Company_url { get; set; }

		[Display(Name = "Street Address")]
		[Required(ErrorMessage = "Street Address is required")]
		public string Street_Address { get; set; }

		[Display(Name = "City")]
		[Required(ErrorMessage = "City is required")]
		public string City { get; set; }

		[Display(Name = "State")]
		[Required(ErrorMessage = "State is required")]
		[MinLength(2)]
		[MaxLength(2)]
		[DataType(DataType.Text)]
		public string State { get; set; }

		[Display(Name = "Zip")]
		[Required(ErrorMessage = "Zip is required")]
		[Range(00000, 99999)]
		public string Zip { get; set; }

		[Display(Name = "Comments")]
		[DataType(DataType.Text)]
		[MaxLength(128)]
		public string Comments { get; set; }


	}
}